]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
chrome: Make affectsStruts default to false
authorDan Winship <danw@gnome.org>
Thu, 21 Jul 2011 14:18:15 +0000 (10:18 -0400)
committerDan Winship <danw@gnome.org>
Wed, 3 Aug 2011 13:17:52 +0000 (09:17 -0400)
Since we only want it to be true for the panel, and nothing else.

https://bugzilla.gnome.org/show_bug.cgi?id=655813

js/ui/chrome.js
js/ui/layout.js
js/ui/messageTray.js
js/ui/panel.js
js/ui/panelMenu.js

index 7110ee5849c95a00a053fa8b0b6b15955ddfdeaf..602b93d238399b960f6f1fd25c0a057672d85391 100644 (file)
@@ -16,7 +16,7 @@ const ScreenSaver = imports.misc.screenSaver;
 
 const defaultParams = {
     visibleInFullscreen: false,
-    affectsStruts: true,
+    affectsStruts: false,
     affectsInputRegion: true
 };
 
@@ -71,19 +71,18 @@ Chrome.prototype = {
     // @actor: an actor to add to the chrome layer
     // @params: (optional) additional params
     //
-    // Adds @actor to the chrome layer and extends the input region
-    // and window manager struts to include it. (Window manager struts
-    // will only be affected if @actor is touching a screen edge.)
-    // Changes in @actor's size and position will automatically result
-    // in appropriate changes to the input region and struts. Changes
-    // in its visibility will affect the input region, but NOT the
-    // struts.
+    // Adds @actor to the chrome layer and (unless %affectsInputRegion
+    // is %false) extends the input region to include it. Changes in
+    // @actor's size, position, and visibility will automatically
+    // result in appropriate changes to the input region.
+    //
+    // If %affectsStruts is %true (and @actor is along a screen edge),
+    // then @actor's size and position will also affect the window
+    // manager struts. Changes to @actor's visibility will NOT affect
+    // whether or not the strut is present, however.
     //
     // If %visibleInFullscreen is %true, the actor will be visible
     // even when a fullscreen window should be covering it.
-    //
-    // If %affectsStruts or %affectsInputRegion is %false, the actor
-    // will not have the indicated effect.
     addActor: function(actor, params) {
         this.actor.add_actor(actor);
         this._trackActor(actor, params);
index a4f49960f63c1d14bf06f8e8f4386f1c676184aa..e13151a980bf1e1cb1e456d106d44ecaade8a936 100644 (file)
@@ -109,7 +109,7 @@ LayoutManager.prototype = {
             let corner = new HotCorner();
             this._hotCorners.push(corner);
             corner.actor.set_position(cornerX, cornerY);
-            Main.chrome.addActor(corner.actor, { affectsStruts: false });
+            Main.chrome.addActor(corner.actor);
         }
     },
 
index 3dea6ff71f3571140342c171d8dcb887ed9f8f38..d7d246deb8b565a2a20fe4c2d66f67e2f041dcdd 100644 (file)
@@ -1330,8 +1330,7 @@ MessageTray.prototype = {
         this._notificationRemoved = false;
         this._reNotifyAfterHideNotification = null;
 
-        Main.chrome.addActor(this.actor, { affectsStruts: false,
-                                           visibleInFullscreen: true });
+        Main.chrome.addActor(this.actor, { visibleInFullscreen: true });
         Main.chrome.trackActor(this._notificationBin);
         Main.chrome.trackActor(this._summaryBoxPointer.actor);
 
index a830a1c84e3ed8feca1256c741df25e66007380f..b0c4f8998275ff1bf819569ca5656b5765948e8d 100644 (file)
@@ -941,11 +941,9 @@ Panel.prototype = {
         Main.statusIconDispatcher.connect('status-icon-added', Lang.bind(this, this._onTrayIconAdded));
         Main.statusIconDispatcher.connect('status-icon-removed', Lang.bind(this, this._onTrayIconRemoved));
 
-        Main.chrome.addActor(this.actor);
-        Main.chrome.addActor(this._leftCorner.actor, { affectsStruts: false,
-                                                       affectsInputRegion: false });
-        Main.chrome.addActor(this._rightCorner.actor, { affectsStruts: false,
-                                                        affectsInputRegion: false });
+        Main.chrome.addActor(this.actor, { affectsStruts: true });
+        Main.chrome.addActor(this._leftCorner.actor, { affectsInputRegion: false });
+        Main.chrome.addActor(this._rightCorner.actor, { affectsInputRegion: false });
 
         Main.ctrlAltTabManager.addGroup(this.actor, _("Top Bar"), 'start-here',
                                         { sortGroup: CtrlAltTab.SortGroup.TOP });
index 6cb96e222f41a88d83b61a427e4147789736a809..4c5ccd3a2b14489b486457165dc6b5af6ffc4b34 100644 (file)
@@ -27,7 +27,7 @@ Button.prototype = {
         this.menu.actor.add_style_class_name('panel-menu');
         this.menu.connect('open-state-changed', Lang.bind(this, this._onOpenStateChanged));
         this.menu.actor.connect('key-press-event', Lang.bind(this, this._onMenuKeyPress));
-        Main.chrome.addActor(this.menu.actor, { affectsStruts: false });
+        Main.chrome.addActor(this.menu.actor);
         this.menu.actor.hide();
     },